package com.qcby.types.pojo;


import com.qcby.types.common.RuleConstants;
import com.qcby.types.exception.IResponse;

public enum BaseResponse implements IResponse {

    SUCCESS(RuleConstants.SUCCESS_CODE, RuleConstants.SUCCESS_MESSAGE),
    INTERNAL_ERROR(RuleConstants.ERROR_CODE, RuleConstants.ERROR_MESSAGE),
    BAD_REQUEST(RuleConstants.BAD_REQ_CODE, RuleConstants.BAD_REQ_MESSAGE);

    private final String code;
    private final String message;

    BaseResponse(String code, String message) {
        this.code = code;
        this.message = message;
    }

    @Override
    public String getCode() {
        return code;
    }

    @Override
    public String getMessage() {
        return message;
    }
}
